/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package jforum.actions;

import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jforum.DAO.MessageDAO;
import jforum.DAO.UserDAO;
import jforum.util.DBConnector;

/**
 * Действие просмотра списка всех пользователей
 * @author Вадим
 */
public class ViewUsersAction implements Action {

    public String perform(HttpServletRequest request, HttpServletResponse response) throws Exception {
        DBConnector conn=DBConnector.getInstance();
        UserDAO dao=new UserDAO(conn);
        List users = dao.LoadActive();
        request.setAttribute("users",users);
        return ActionNames.users_page;
    }


}
